package com.face.recognition;

import com.arcsoft.face.FaceEngine;
import com.arcsoft.face.enums.ErrorInfo;

public class FaceActivation {

    public static void main(String[] args) {
        String appId = "DedZVeSxiAt7UpHr8kuRkrEHdBuXmbXknsesSWM3Ki6f";
        String sdkKey = "FtHFNmJ5rtEa2W6Ws8tvHw7B2QcntCqReBnwqWpM6Ek9";

        FaceEngine faceEngine = new FaceEngine("D:\\FaceDLL");
        //激活引擎
        int errorCode = faceEngine.activeOnline(appId, sdkKey);

        if (errorCode != ErrorInfo.MOK.getValue() && errorCode != ErrorInfo.MERR_ASF_ALREADY_ACTIVATED.getValue()) {
            System.out.println("引擎激活失败");
        } else {
            System.out.println("引擎激活成功");
        }
    }

}
